home *** CD-ROM | disk | FTP | other *** search
/ Sky at Night 2007 June / SAN CD 6-2007 CD-ROM 25.iso / pc / Software / AstroGrav_Win / Java / jre1.6.0 / lib / rt.jar / sun / misc / URLClassPath$1.class (.txt) < prev    next >
Encoding:
Java Class File  |  2006-11-29  |  1.1 KB  |  55 lines

  1. package sun.misc;
  2.  
  3. import java.net.URL;
  4. import java.util.Enumeration;
  5. import java.util.NoSuchElementException;
  6.  
  7. final class URLClassPath$1 implements Enumeration {
  8.    private int index;
  9.    private URL url;
  10.    // $FF: synthetic field
  11.    final String val$name;
  12.    // $FF: synthetic field
  13.    final boolean val$check;
  14.    // $FF: synthetic field
  15.    final URLClassPath this$0;
  16.  
  17.    URLClassPath$1(URLClassPath var1, String var2, boolean var3) {
  18.       this.this$0 = var1;
  19.       this.val$name = var2;
  20.       this.val$check = var3;
  21.       this.index = 0;
  22.       this.url = null;
  23.    }
  24.  
  25.    private boolean next() {
  26.       if (this.url != null) {
  27.          return true;
  28.       } else {
  29.          URLClassPath.Loader var1;
  30.          while((var1 = URLClassPath.access$000(this.this$0, this.index++)) != null) {
  31.             this.url = var1.findResource(this.val$name, this.val$check);
  32.             if (this.url != null) {
  33.                return true;
  34.             }
  35.          }
  36.  
  37.          return false;
  38.       }
  39.    }
  40.  
  41.    public boolean hasMoreElements() {
  42.       return this.next();
  43.    }
  44.  
  45.    public Object nextElement() {
  46.       if (!this.next()) {
  47.          throw new NoSuchElementException();
  48.       } else {
  49.          URL var1 = this.url;
  50.          this.url = null;
  51.          return var1;
  52.       }
  53.    }
  54. }
  55.